Skip to content

[mlir][cmake] Fix mlir target export #153341

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

brnorris03
Copy link
Contributor

In #152195, target export was accidentally moved inside a conditional, but it should have been left outside. This patch undoes that change.

@brnorris03 brnorris03 marked this pull request as ready for review August 14, 2025 01:02
@llvmbot llvmbot added the mlir label Aug 14, 2025
@llvmbot
Copy link
Member

llvmbot commented Aug 14, 2025

@llvm/pr-subscribers-mlir

Author: Boyana Norris (brnorris03)

Changes

In #152195, target export was accidentally moved inside a conditional, but it should have been left outside. This patch undoes that change.


Full diff: https://github.com/llvm/llvm-project/pull/153341.diff

1 Files Affected:

  • (modified) mlir/cmake/modules/AddMLIR.cmake (+1-1)
diff --git a/mlir/cmake/modules/AddMLIR.cmake b/mlir/cmake/modules/AddMLIR.cmake
index 14eefb50ca714..38839679ef8b1 100644
--- a/mlir/cmake/modules/AddMLIR.cmake
+++ b/mlir/cmake/modules/AddMLIR.cmake
@@ -641,8 +641,8 @@ function(add_mlir_library_install name)
                               COMPONENT ${name})
     endif()
     set_property(GLOBAL APPEND PROPERTY MLIR_ALL_LIBS ${name})
-    set_property(GLOBAL APPEND PROPERTY MLIR_EXPORTS ${name})
   endif()
+  set_property(GLOBAL APPEND PROPERTY MLIR_EXPORTS ${name})
 endfunction()
 
 # Declare an mlir library which is part of the public C-API.

@brnorris03
Copy link
Contributor Author

@christopherbate This undoes an accidental move of the target export line, which was merged with #152195 (sorry about that!).

@ElvinaYakubova
Copy link
Contributor

As I said in the original PR, this fixes our build issue, so LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants